package cate.game.admin.menu.show;

import cate.game.GameBody;
import cate.game.admin.menu.MenuSetup;
import cate.game.role.res.hero.introduction.HeroIntroduction;
import cate.game.role.show.heroskin.RoleHeroSkin;
import cate.game.role.show.leaderskin.RoleLeaderSkin;
import cate.game.role.show.msg.LeaderSkinOnResp;

public class ShowMenu extends MenuSetup {

    public ShowMenu(GameBody game) {
        super("饰品");
        reg(
                game,
                "清空皮肤图鉴",
                0,
                "英雄和主角都清除",
                (role, params) -> {
                    role.getShow().heroSkin = new RoleHeroSkin();
                    role.getShow().heroSkin.initialize(role);

                    role.getShow().leaderSkin = new RoleLeaderSkin();
                    role.getShow().leaderSkin.initialize(role);
                    role.getBase().leaderSkin = 0;
                    role.sendNow(new LeaderSkinOnResp(0));
                    role.getShow().noticeUpdate();

                    role.getRes().heroIntroduction = new HeroIntroduction();
                    role.getRes().heroIntroduction.initialize(role);
                    role.getRes().heroIntroduction.noticeUpdate();

                    game.notice.message(role, "成功");
                });
    }
}
